<template>
  <div class="minor-header">
    <div class="wrap f-sb-c">
      <h1>
        <router-link to="/"
          ><img src="@/public/img/logo.jpg"
        /></router-link>
      </h1>
      <h1 id="title">{{ title }}</h1>
      <div id="go-page">
        <span @click="$router.go(-1)"
          ><i class="el-icon-caret-left"></i> 返回上一页</span
        >
        <span @click="$router.push('/')"
          ><i class="el-icon-s-home"></i> 返回首页</span
        >
      </div>
    </div>
  </div>
</template>
<script>
export default {
  name: "mainorHeader",
  props: ["title"],
  data() {
    return {};
  },
};
</script>
<style lang="scss" scoped>
.wrap {
  height: 80px;
}
.minor-header {
  background: #eeeeee;
}
#title {
  color: $theme-color;
  font-size: 30px;
}
#go-page span {
  cursor: pointer;
  color: $theme-color;
  margin-left: 1em;
  font: {
    size: 18px;
    weight: bold;
  }
  &:hover{
    text-decoration: underline;
  }
}
h1 {
  padding: 0;
  margin: 0;
  img {
    height: 40px;
  }
}
</style>